package com.e_manager.soft.emanager.resultMsg;

/**
 * @author : lip[lip4051@163.com]
 * @create : 2018/3/13 0013 下午 4:12
 */
public enum ResultConstant {
    SUCCESS(0, "成功"),
    FAIL(5, "失败"),
    UN_AUTHORIZED(12, "授权失败"),
    CHECK_CODE_FAIL(4,"验证码不对或已失效"),
    USER_ALREADY_EXISTS(1,"用户已存在"),
    USERNAME_OR_PASSWORD_ERROR(3, "用户名或密码错误"),
    USER_NOT_FOUND(6, "用户不存在"),
    USER_NOT_LOGIN(7, "用户未登录"),
    PARAMS_ERROR(8,"参数传递错误"),
    FILE_NOT_FOUND(9, "文件为空"),
    GET_MESSAGE_FIIL(11,"查询数据失败"),
    INSERT_FAIL(14,"保存数据失败"),
    EQUIPMENT_NOT_EXESITS(13,"设备不存在"),
    FILE_FAIL(10, "上传失败");

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }

    /**
     * 返回码
     */
    private int code;
    /**
     *返回结果信息
     */
    private String message;

    ResultConstant(int code, String message) {
        this.code = code;
        this.message = message;
    }
}
